<?php
include('php/db.php');
date_default_timezone_set('Asia/Hong_Kong');
$today = date('Y-m-d');
$getdate = mysql_query("SELECT * FROM `flss`.`job_order`");
while($daterow = mysql_fetch_array($getdate))
{
	$getclosing = $daterow['Job_cdate'];
	if($getclosing == $today)
	{
		$getjobid = $daterow['job_id'];
		mysql_query("UPDATE job_order SET Status = '4' WHERE job_id = '$getjobid'");
		}
	}	
	
?>